package com.student.db;

import androidx.room.Dao;
import androidx.room.Insert;
import androidx.room.OnConflictStrategy;
import androidx.room.Query;

import java.util.List;

import io.reactivex.rxjava3.core.Completable;
import io.reactivex.rxjava3.core.Flowable;

@Dao
public interface PushDao {
    @Insert(onConflict = OnConflictStrategy.REPLACE)
    public Completable insert(PushEntity pushEntity);

    @Query("Select * from db_push  ORDER BY pushTime DESC")
    public Flowable<List<PushEntity>> getAllPush();
}
